<!DOCTYPE html>
<html xmlns:th="http://www.w3.org/1999/xhtml">
<head>
    <link href="images/5.icon" rel="icon" type="image/x-icon"/>
    <link rel="stylesheet" href="node_modules/bootstrap/dist/css/bootstrap.css">
    <link rel="stylesheet" href="css/index.css">
    <meta charset="utf-8">
    <title>体检项目明细</title>
    <style type="text/css">
        * {
            padding: 0;
            margin: 0;
        }

        body {
            background-color: whitesmoke
        }

        .mingxi {
            width: 700px;
            height: 900px;
            background-color: #F1F1F1;
            margin: 50px auto;
            border: 3px solid #ccc;
            border-radius: 5%;
        }

        .tou {
            width: 300px;
            height: 50px;
            margin: 30px auto;
            background-color: deepskyblue;
            text-align: center;
            border-radius: 150px;
            color: white;
            margin-top: -30px;
        }

        h1 {

            font-weight: normal;
        }

        table {
            margin: 30px auto;
            line-height: 5px;
            text-align: center;
            font-size: 14px;
            background-color: whitesmoke;
            border: black;

        }

        .yuyue {
            width: 200px;
            height: 50px;
            margin: 30px auto;
            text-align: center;
            background-color: red;
            border-radius: 100px;
        }

        #yuyue {
            color: white;
            line-height: 50px;
            text-decoration: none;
            font-size: 20px;
            font-weight: 700;
        }

    </style>
</head>
<body>
<input id="examinePackageId" th:value="${examinePackageId}" hidden>
<input id="unitId" th:value="${unitId}" hidden>
<input hidden type="text" id="loginStatus" th:value="${session.login}">
<div class="mingxi">
    <div class="tou">
        <h1>体检项目明细</h1>
    </div>
    <table width="600" height="800" border="1" rules="all">
        <tr>
            <td colspan="4">科室检查(2项)</td>

        </tr>
        <tr>
            <td>科室检查(2项)</td>
            <td colspan="3">内外科、眼科、耳鼻喉、眼底成像、纯音听阈</td>

        </tr>
        <tr>
            <td>妇检</td>
            <td colspan="3">妇科检查 液基薄层细胞学检测（TCT） 人乳头瘤病毒检测（HPV）</td>

        </tr>
        <tr>
            <td colspan="4">实验室检查(6项)</td>

        </tr>
        <tr>
            <td>尿常规+沉渣</td>
            <td colspan="3">尿常规、尿沉渣计数</td>

        </tr>
        <tr>
            <td>甲功5项</td>
            <td colspan="3">甲功五项</td>

        </tr>
        <tr>
            <td>同型半胱氨酸</td>
            <td colspan="3">同性半胱氨酸</td>

        </tr>
        <tr>
            <td>肿瘤筛查</td>
            <td colspan="3">肿瘤标志物检测（女）</td>

        </tr>
        <tr>
            <td>血常规</td>
            <td colspan="3">血常规检查</td>

        </tr>
        <tr>
            <td>生化常规</td>
            <td colspan="3">肝功、肾功、血糖、血脂/SOD</td>

        </tr>
        <tr>
            <td colspan="4">医技检查(4项)</td>

        </tr>
        <tr>
            <td>彩超检查</td>
            <td colspan="3">上腹部彩超 下腹部彩超 甲状腺彩超 双侧乳腺彩超</td>

        </tr>
        <tr>
            <td>头颅CT检查</td>
            <td colspan="3">精确检查颅内肿瘤、脑栓塞、脑血管畸形、脑软化、脑萎缩、脑部炎症、结核等</td>

        </tr>
        <tr>
            <td>骨密度</td>
            <td colspan="3">骨质疏松症</td>

        </tr>
        <tr>
            <td>14碳呼气验</td>
            <td colspan="3">C14幽门螺杆菌呼气试验检测</td>

        </tr>
        <tr>
            <td colspan="4">其他(2项)</td>

        </tr>
        <tr>
            <td>其他</td>
            <td colspan="3">采血费</td>

        </tr>
        <tr>
            <td>优享服务</td>
            <td colspan="3">专家解读报告 医生咨询服务</td>

        </tr>
    </table>

</div>
<div class="yuyue">
    <a href="#" id="yuyue" data-toggle="modal" data-target="#exampleModalCenter">立即预约</a>
</div>
<div class="yuyue">
    <a href="#" id="goBackTaocan">返回</a>
</div>

<div class="modal fade" id="exampleModalCenter" tabindex="-1" role="dialog" aria-labelledby="exampleModalCenterTitle" aria-hidden="true">
    <div class="modal-dialog modal-dialog-centered" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <h5 class="modal-title" id="exampleModalCenterTitle">预约</h5>
                <button type="button" class="close" data-dismiss="modal" aria-label="Close">
                    <span aria-hidden="true">&times;</span>
                </button>
            </div>
            <div class="modal-body">
                <form class="clearfix">
                    <!--<div class="form-group row">
                        <label for="count" class="col-sm-2 col-form-label" style="text-align: right">邮箱</label>
                        <div class="col-sm-10">
                            <input type="text" class="form-control" id="count" placeholder="请输入邮箱" name="email">
                        </div>
                    </div>-->
                    <!--<div class="form-group row">
                        <label for="userPassword" class="col-sm-2 col-form-label" style="text-align: right">婚姻状况</label>
                        <div class="col-sm-10">
                            <input type="password" class="form-control" id="userPassword" placeholder="请输入密码" name="password">
                        </div>
                    </div>-->
                    <div class="row">
                        <label for="code_input" class="col-sm-2 col-form-label" style="text-align: right" >日期</label>
                        <div class="col-sm-10">
                            <input type="date" class="form-control d-inline-block" id="code_input" name="examineDate"  style="width: 50%">
                            <div id="v_container" class="d-inline-block ml-3"></div>
                        </div>
                    </div>
                    <button type="button" class="btn btn-primary float-right" id="yuyueBtn" style="width: 100px">登录</button>
                </form>
            </div>
        </div>
    </div>
</div>

<script src="node_modules/jquery/dist/jquery.js"></script>
<script src="node_modules/bootstrap/dist/js/bootstrap.js"></script>
<script src="js/index.js"></script>
<script src="js/gVerify.js"></script>
<!--<script src="js/jquery.js"></script>-->
<script>
    let unitId = $("#unitId").val();
    let loginStatus=$("#loginStatus").val();
    let examinePackageId = $("#examinePackageId").val();
    $("#yuyueBtn").on("click", function () {
        console.log("提交");
        let examineDate=$("input[name=examineDate]").val();
        console.log(examineDate+"\t"+unitId+"\t"+examinePackageId+"\t"+loginStatus);
        if(loginStatus!="true"){
            alert("请先登录！","温馨提示");
            window.location.href="/index";
        }else{
            $.ajax({
                url: "/bookExamine",//nePackageId=" + examinePackageId + "&unitId=" + unitId+"&examineDate="+examineDate,
                type: "post",
                data: "examinePackageId=" + examinePackageId + "&unitId=" + unitId+"&examineDate="+examineDate,
                success: function (responseResult) {
                    console.log("数据提交成功");
                    alert(responseResult.msg);
                },
                error: function () {
                    console.log("数据提交失败");
                }
            });
        }


        //return false;
    });

    $("#goBackTaocan").on("click", function(){
        window.location.href="/xiangqing?unitId="+unitId;
    });

</script>

</body>
</html>
